cc.Class({
  extends: cc.Component,

  properties: {},

  start: function() {
    console.log('开始接受');
    // 接收主域消息
    wx.onMessage(data => {
      switch (data.message) {
        case 'rankPage':
          console.log('收到显示排行页面');
          cc.director.loadScene("rankPage");
          break;
      }
    });
  },
});